Skip to content

Specify fix text built from facts for pressure points and supporting detail - #78

Merged
Pranav-Mathad merged 1 commit into
mainfrom
issue-74-spec-suggested-improvements
Nov 29, 2026
Merged

Pranav-Mathad merged 1 commit into
mainfrom
issue-74-spec-suggested-improvements

Conversation

@Pranav-Mathad

Copy link
Copy Markdown
Owner

Part of #74. This is the spec step that issue asks for first; the code follows in its own pull request, so this one does not close the issue.

Why

The judging hints ask that the tool "suggests realistic improvements", and §11.4 says each of the top 10 carries a fix. But three finding types get no fix anywhere: job B does not judge them, and the template returns an empty fix for every type except the cheap loop. Ranks 1 to 3 in all three repositories are shaky foundations, so the list opens on findings with nothing to do.

What changes in spec.md

  • §8.7 The template now also gives a fix sentence for shaky foundation, hidden partners and "large, complex, often changed". Rules: built only from stored facts and evidence, no AI call, every number is a fact value, at most 2 sentences, an existing fix.action value, shown as "not simulated". A finding with no fix says "No improvement proposed." and never shows an empty field.
  • §8.3 One sentence: job B does not judge pressure points or supporting detail; their fix text comes from §8.7.
  • §11.4 Item 3 says what is shown when there is no fix and when a fix was not simulated.
  • §14 One limit: these suggestions are standard remedies by finding type, filled with the finding's facts, not written from a reading of the code.
  • §1.3 One decision-log row for this choice.
Type Action Fix sentence
Shaky foundation split_by_responsibility Separate the part of {file} that changes often from the part that stays, so its {direct_users} direct users depend only on the part that stays.
Hidden partners extract_interface Move what {a} and {b} share into one place that both use. If they must stay apart, a note in each that names the other makes the pairing visible.
Large, complex, often changed split_by_responsibility Split {top_functions} into smaller functions. No other function in {file} has more branches.

No contract, schema or settings change. Every placeholder is a value the findings already store (direct_users, top_functions, the targets), checked against results/artemis/findings.json, so the code step needs no new Stage 5 fact.

The alternative, extending job B to these types, was not taken: it needs new verdicts, a change to core/contracts.py and more AI calls, and the model would see about 250 lines of a file that hundreds of others use.

Not in conflict with #77

#77 changes the "Slipping" row in §9.2, the "Foundation depending on features" row in §9.3 and the "Before and after" row in §10.2. None of those lines is touched here.

What I ran and saw

  • git diff --stat origin/main: spec.md only, 23 insertions and 1 deletion.
  • uv run ruff check .: "All checks passed!"
  • uv run pytest -q: 36 passed, 1 skipped (the empty STUBS parameter set in tests/test_cli.py).
  • The web checks were not run locally: nothing under web/ changed. CI runs them.
  • Nothing was run on a repository, because this pull request changes no behaviour.

@Pranav-Mathad
Pranav-Mathad merged commit 3ee83ae into main Nov 29, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant